from pydantic import BaseModel, Field
from typing import Optional


from mldong.base import BasePageParam


class UserParam(BaseModel):
    id: Optional[str] = Field(None, title="主键", description="主键")

    
    
    userName: str = Field(..., title="用户名", description="用户名")
    
    realName: str = Field(..., title="姓名", description="姓名")
    
    nickName: Optional[str] = Field(None, title="昵称", description="昵称")
    
    avatar: Optional[str] = Field(None, title="用户头像", description="用户头像")
    
    password: Optional[str] = Field(None, title="用户密码", description="用户密码")
    
    salt: Optional[str] = Field(None, title="密码加盐", description="密码加盐")
    
    mobilePhone: str = Field(..., title="手机号", description="手机号")
    
    tel: Optional[str] = Field(None, title="联系电话", description="联系电话")
    
    email: Optional[str] = Field(None, title="邮箱", description="邮箱")
    
    adminType: Optional[int] = Field(None, title="管理员类型<sys_admin_type>", description="管理员类型<sys_admin_type>")
    
    sex: int = Field(..., title="性别<sys_sex>", description="性别<sys_sex>")
    
    isLocked: int = Field(..., title="是否锁定", description="是否锁定")
    
    deptId: Optional[str] = Field(None, title="所属部门", description="所属部门")
    
    postId: Optional[str] = Field(None, title="所属岗位", description="所属岗位")
    
    remark: Optional[str] = Field(None, title="备注", description="备注")
    
    
    
    
    
    


class UserPageParam(BasePageParam):
    pass